package abstract01;


import abstract01.factory.HuaWeiFactory;
import abstract01.factory.XiaomiProductFactory;
import abstract01.java.IponeProduct;
import abstract01.java.Router;

/**
 * @author feng
 * @Date 2021/10/14 21:59
 */
public class Celint {
    public static void main(String[] args) {
        XiaomiProductFactory xiaomiProductFactory = new XiaomiProductFactory();
        IponeProduct xiaomiPone = xiaomiProductFactory.PhoneFactory();
        xiaomiPone.call();
        xiaomiPone.sellMessage();
        Router xiaomirouter = xiaomiProductFactory.routerFactory();
        xiaomirouter.openR();
        xiaomirouter.sendWiFi();
        System.out.println("=============华为系列================");
        HuaWeiFactory huaWeiFactory = new HuaWeiFactory();
        IponeProduct huaweiPhone = huaWeiFactory.PhoneFactory();
        huaweiPhone.sellMessage();
        huaweiPhone.call();
        Router huaweirouter = huaWeiFactory.routerFactory();
        huaweirouter.openR();
        huaweirouter.playR();
    }
}
